


/* 数字格式化成字符串 */
export function transformNumber(num,n){
  let str = num.toString()
  const gap = n - str.length
  if(gap <= 0){
    return str
  }else{
    for(let i=1; i<=gap; i++)
      str = '0'+str
    return str
  }
}



/* 分割 */ 
export function splitBy(string,separator){
  return string.split(separator).filter((it,i)=>{
    if(it=='')
      return false
    else
      return true
  })
}
